# -*- coding:utf-8 -*-

from com.mat.rpa.utils.globalConstants import GlobalConstants
from com.mat.rpa.views.workWindow.leftPanel.directiveTree import treeItem
from . import compressingOrDecompressingOperationConstants

class CompressingOrDecompressingOperationSubDirectiveTree(treeItem.TreeItemWithID):
    def __init__(self, parent):
        super(CompressingOrDecompressingOperationSubDirectiveTree, self).__init__(parent)
        self.createCompressingOrDecompressingOperationTreeNode()

    def createCompressingOrDecompressingOperationTreeNode(self):
        self.nodeType = GlobalConstants.treeBranchType
        self.directiveType = "compressingOrDecompressingOperations"
        self.setText(0,"压缩/解压缩")
        self.createTreeNode(GlobalConstants.treeLeafType,
                            self, compressingOrDecompressingOperationConstants.CompressingOrDecompressingOperationConstants.compressingFileOrFolderDirective, "压缩文件或文件夹")
        self.createTreeNode(GlobalConstants.treeLeafType,
                            self, compressingOrDecompressingOperationConstants.CompressingOrDecompressingOperationConstants.decompressingFileOrFolderDirective, "解压文件或文件夹")